Learn how to set up the Algolia cartridge for Salesforce B2C Commerce.
Cartridge name | Purpose |
---|---|
bm_algolia | Configure and monitor Algolia indexing and search from your Business Manager (adding a corresponding Merchant Tools module) |
int_algolia | Synchronize (index) your product catalog and content data from B2C Commerce to Algolia |
int_algolia_sfra | Add Algolia InstantSearch and Autocomplete on your SFRA storefront |
int_algolia_controllers algolia_sg_changes | Add Algolia InstantSearch and Autocomplete to your SiteGenesis storefront |
dw.json
file in the same directory with the following content:
hostname
the hostname of your sandbox—for example: "zzaa-001.sandbox.us01.dx.commercecloud.salesforce.com"
username
and password
are your account manager credentialscode-version
is the active code version listed in Administration > Code Deployment—for example, "SFRA_AP_05_15_2020"
dw.json
file in the same directory with the following content:
Prophet: Enable Upload
from the command menu.
int_algolia_sfra:int_algolia
to the beginning of your cartridge path.
SiteGenesis
algolia_sg_changes:int_algolia_controllers
to the beginning of your cartridge path.int_algolia
to the end of your cartridge path.int_algolia
to the beginning of your cartridge path.
bm_algolia:int_algolia
at the end of your cartridge path.
metadata/algolia/meta
folder by clicking Choose File, then Upload. Do this for both custom-objecttype-definitions.xml
and system-objecttype-extensions.xml
.
custom-objecttype-definitions.xml
, click Next, then Import.
system-objecttype-extensions.xml
as well.
metadata/algolia
folder by clicking Choose File, then Upload. Do this for both jobs.xml
and services.xml
.
jobs.xml
and click Next, Next, then Import.
services.xml
and click Next, Next, then Import.
name
, primary_category_id
, categories
, url
, image_groups
, in_stock
, price
.
Consider adding these attributes: short_description
and long_description
.
Then, expand the list to include attributes specific to your product catalog, such as, brand
, color
, or size
.
The content attributes you want to index are managed using the attributeList
job step parameter. For more information, see the Content indexing job configuration.
app_storefront_base/cartridge/templates/default/common/htmlHead.isml
, add the following code on line 32:
app_storefront_base/cartridge/templates/default/components/header/search.isml
,
add the following code at the start of the file, and move existing the code to an <iselse>
section:
app_storefront_base/cartridge/templates/default/search/searchResult.isml
,
replace this line: